<!DOCTYPE html>
<html lang="zh-CN">
    <head>
        <meta charset="UTF-8" />
        <title>20_鼠标事件-鼠标左键-双击-ondblclick</title>
        <style>
            div {
                width: 200px;
                height: 200px;
                background-color: aquamarine;
            }
        </style>
    </head>
    <body>
        <div></div>

        <script>
            var div = document.querySelector('div');

            div.ondblclick = function(){
                console.log(2222);
            }
        </script>
    </body>
</html>